//全部学员信息查询
function queryStu(data){
    for (var i = 0; i< data.length; i++) {
        var team = $('<tr></tr>');
        team.append('<td>' + data[i].semesterName + '</td>');
        team.append('<td style="display: none">' + data[i].studentNumber + '</td>');
        team.append('<td>' + data[i].studentName + '</td>');
        team.append('<td>' + data[i].age + '</td>');
        team.append('<td>' + sexDecide(data[i].genderNumber) + '</td>');
        team.append('<td>' + data[i].phone + '</td>');
        team.append('<td>' + data[i].academicName + '</td>');
        team.append('<td>' + data[i].identityNumber + '</td>');
        team.append('<td>' + data[i].homeAddress + '</td>');
        team.append('<td>' + data[i].emergencyContactName + '</td>');
        team.append('<td>' + data[i].emergencyContactRelationship + '</td>');
        team.append('<td>' + data[i].emergencyContactPhone + '</td>');
        team.append('<td>' + data[i].preVocational + '</td>');
        team.append('<td>' + data[i].studentAdmissionType + '</td>');
        team.append('<td>' + data[i].introducer + '</td>');
        team.append('<td>' + data[i].dormitoryNumber + '</td>');
        team.append('<td>' + date(data[i].registrationDate) + '</td>');
        team.append('<td><input type="button" value="修改" class="modify-btn" id="modifyBtn" /></td>');
        // team.append('<td><input type="button" value="查看" class="modify-btn" id="lookBtn"/></td>');
        $("#J_queryStu").append(team);
    }
}

// 单个学员信息查询
// function queryStuId(){
//     for (var i = 0; i < data.length; i++) {
//         var team = $('<tr></tr>');
//         team.append('<td>' + data[i].semester + '</td>');
//         team.append('<td>' + data[i].studentId + '</td>');
//         team.append('<td>' + data[i].studentName + '</td>');
//         team.append('<td>' + data[i].studentAge + '</td>');
//         team.append('<td>' + data[i].studentSex + '</td>');
//         team.append('<td>' + data[i].studentPhone + '</td>');
//         team.append('<td>' + data[i].studentQualificationsName + '</td>');
//         team.append('<td>' + data[i].preStudentOccupation + '</td>');
//         team.append('<td>' + data[i].studentHomeAddress + '</td>');
//         team.append('<td>' + data[i].admissionTypeName + '</td>');
//         team.append('<td>' + data[i].studentIntroducer + '</td>');
//         team.append('<td>' + data[i].studentIdNumber + '</td>');
//         team.append('<td>' + data[i].studentRegistrationDate + '</td>');
//         team.append('<td>' + data[i].studentDormitoryName + '</td>');
//         team.append('<td>' + data[i].remarks + '</td>');
//         team.append('<td><input type="button" value="修改" class="modify-btn"/></td>');
//         $("#J_queryStuId").append(team);
//     }
// }

// 联系人关系表信息查询
function queryEgcrs(data){
    for (var i = 0; i < data.length; i++) {
        var team = $('<tr></tr>');
        team.append('<td>' + data[i].emergencyContactRelationship + '</td>');
        team.append('<td>' + data[i].founder + '</td>');
        team.append('<td>' + date(data[i].founderTime) + '</td>');
        team.append('<td>' + (data[i].updater == null ? "-":data[i].updater) + '</td>');
        team.append('<td>' + (data[i].updaterTime==null?"-":data[i].updaterTime) + '</td>');
        //team.append('<td><input type="button" value="修改" class="modify-btn" name="queryEgcrs-modify-btn"/></td>');
        $("#J_queryEgcrs").append(team);
    }
}

// 全部入学类型信息查询
function queryAdmType(data){
    for (var i = 0; i < data.length; i++) {
        var team = $('<tr></tr>');
        team.append('<td>' + data[i].studentAdmissionType + '</td>');
        team.append('<td>' + data[i].founder + '</td>');
        team.append('<td>' + date(data[i].founderTime) + '</td>');
        team.append('<td>' + (data[i].updater == null ? "-":data[i].updater) + '</td>');
        team.append('<td>' + (data[i].updaterTime==null?"-":data[i].updaterTime) + '</td>');
        // team.append('<td>' + data[i].updater + '</td>');
        // team.append('<td>' + data[i].updateTime + '</td>');
        //team.append('<td><input type="button" value="修改" class="modify-btn" name="queryAdmType-modify-btn"/></td>');
        $("#J_queryAdmType").append(team);
    }
}

// 全部学历信息查询
function queryEducation(data){
    for (var i = 0; i < data.length; i++) {
        var team = $('<tr></tr>');
        team.append('<td>' + data[i].academicName + '</td>');
        team.append('<td>' + data[i].founder + '</td>');
        team.append('<td>' + date(data[i].founderTime) + '</td>');
        team.append('<td>' + (data[i].updater == null ? "-":data[i].updater) + '</td>');
        team.append('<td>' + (data[i].updaterTime==null?"-":data[i].updaterTime) + '</td>');
        // team.append('<td>' + data[i].updater + '</td>');
        // team.append('<td>' + data[i].updateTime + '</td>');
        //team.append('<td><input type="button" value="修改" class="modify-btn" name="queryEducation-modify-btn"/></td>');
        $("#J_queryEducation").append(team);
    }
}

// 查询全部学期信息
function querySem(data){
    for (var i = 0; i < data.length; i++) {
        var team = $('<tr></tr>');
        team.append('<td>' + data[i].semesterName + '</td>');
        team.append('<td>' + date(data[i].startDate) + '</td>');
        team.append('<td>' + data[i].founder + '</td>');
        team.append('<td>' + date(data[i].founderTime) + '</td>');
        team.append('<td>' + (data[i].updater == null ? "-":data[i].updater) + '</td>');
        team.append('<td>' + (data[i].updaterTime==null?"-":data[i].updaterTime) + '</td>');
        // team.append('<td>' + data[i].updater + '</td>');
        // team.append('<td>' + data[i].updateTime + '</td>');
        //team.append('<td><input type="button" value="修改" class="modify-btn" name="querySem-modify-btn"/></td>');
        $("#J_querySem").append(team);
    }
}

// 查询全部宿舍信息
function queryDorm(data){
    for (var i = 0; i < data.length; i++) {
        var team = $('<tr></tr>');
        team.append('<td>' + data[i].dormitoryNumber + '</td>');
        team.append('<td>' + data[i].totalBed + '</td>');
        team.append('<td>' + data[i].remainingBed + '</td>');
        team.append('<td>' + data[i].dormitoryProperty + '</td>');
        team.append('<td>' + data[i].roomPassword + '</td>');
        team.append('<td>' + data[i].founder + '</td>');
        team.append('<td>' + date(data[i].founderTime) + '</td>');
        team.append('<td>' + (data[i].updater == null ? "-":data[i].updater) + '</td>');
        team.append('<td>' + (data[i].updaterTime==null?"-":data[i].updaterTime) + '</td>');
        // team.append('<td>' + data[i].updater + '</td>');
        // team.append('<td>' + data[i].updateTime + '</td>');
        //team.append('<td><input type="button" value="修改" class="modify-btn" name="queryDorm-modify-btn"/></td>');
        $("#J_queryDorm").append(team);
    }
}

// 查询单个宿舍信息
// function queryDormId(){
//     for (var i = 0; i < data.length; i++) {
//         var team = $('<tr></tr>');
//         team.append('<td>' + data[i].dormitoryNumber + '</td>');
//         team.append('<td>' + data[i].totalBed + '</td>');
//         team.append('<td>' + data[i].remainingBed + '</td>');
//         team.append('<td>' + data[i].dormitoryProperty + '</td>');
//         team.append('<td>' + data[i].roomPassword + '</td>');
//         team.append('<td><input type="button" value="修改" class="modify-btn"/></td>');
//         $("#J_queryDormId").append(team);
//     }
// }

//单学生ID查询费用信息
// function queryTuition(){
//     for (var i = 0; i < data.length; i++) {
//         var team = $('<tr></tr>');
//         team.append('<td>' + data[i].studentNumber + '</td>');
//         team.append('<td>' + data[i].stuTuitionName + '</td>');
//         team.append('<td>' + data[i].disInfId + '</td>');
//         team.append('<td>' + data[i].disInfName + '</td>');
//         team.append('<td>' + data[i].stuTuitionAmount + '</td>');
//         team.append('<td>' + data[i].stuRegisteryFee + '</td>');
//         team.append('<td>' + data[i].stuTuitionPaid + '</td>');
//         team.append('<td>' + data[i].surplus + '</td>');
//         team.append('<td>' + data[i].userCreation + '</td>');
//         team.append('<td>' + date(data[i].userCreationDate) + '</td>');
//         team.append('<td>' + data[i].userUpdate + '</td>');
//         team.append('<td>' + date(data[i].userUpdateDate) + '</td>');
//         team.append('<td><input type="button" value="修改" class="modify-btn"/></td>');
//         $("#J_queryTuition").append(team);
//     }
// }

// 查询全部费用信息
function queryTui(data){
    for (var i = 0; i < data.length; i++) {
        var team = $('<tr></tr>');
        //team.append('<td>' + data[i].tuitionInfNumber + '</td>');
        team.append('<td>' + data[i].tuitionName + '</td>');
        team.append('<td>' + data[i].tuitionAmount + '</td>');
        team.append('<td>' + (data[i].tuitionDescription == null ? "-":data[i].updater) + '</td>');
        //team.append('<td>' + data[i].tuitionDescription + '</td>');
        team.append('<td>' + data[i].founder + '</td>');
        team.append('<td>' + date(data[i].founderTime) + '</td>');
        team.append('<td>' + (data[i].updater == null ? "-":data[i].updater) + '</td>');
        team.append('<td>' + (data[i].updaterTime==null?"-":data[i].updaterTime) + '</td>');
        // team.append('<td>' + data[i].updater + '</td>');
        // team.append('<td>' + data[i].updateTime + '</td>');
        //team.append('<td><input type="button" value="修改" class="modify-btn" name="queryTui-modify-btn"/></td>');
        $("#J_queryTui").append(team);
    }
}

// 费用信息ID查询
// function queryTuiNumber(){
//     for (var i = 0; i < data.length; i++) {
//         var team = $('<tr></tr>');
//         team.append('<td>' + data[i].tuitionInfNumber + '</td>');
//         team.append('<td>' + data[i].tuitionName + '</td>');
//         team.append('<td>' + data[i].tuitionAmount + '</td>');
//         team.append('<td>' + data[i].tuitionDescription + '</td>');
//         team.append('<td>' + data[i].founder + '</td>');
//         team.append('<td>' + data[i].founderTime + '</td>');
//         team.append('<td>' + data[i].updater + '</td>');
//         team.append('<td>' + data[i].updateTime + '</td>');
//         team.append('<td><input type="button" value="修改" class="modify-btn"/></td>');
//         $("#J_queryTuiNumber").append(team);
//     }
// }

// 查询所有优惠信息
function queryDisc(data){
    for (var i = 0; i < data.length; i++) {
        var team = $('<tr></tr>');
        // team.append('<td>' + data[i].discountInfNumber + '</td>');
        team.append('<td>' + data[i].discountInfName + '</td>');
        team.append('<td>' + data[i].discountAmount + '</td>');
        team.append('<td>' + (data[i].discountDescription == null ? "-":data[i].updater) + '</td>');
        //team.append('<td>' + data[i].discountDescription + '</td>');
        team.append('<td>' + data[i].founder + '</td>');
        team.append('<td>' + date(data[i].founderTime) + '</td>');
        team.append('<td>' + (data[i].updater == null ? "-":data[i].updater) + '</td>');
        team.append('<td>' + (data[i].updaterTime==null?"-":data[i].updaterTime) + '</td>');
        // team.append('<td>' + data[i].updater + '</td>');
        // team.append('<td>' + data[i].updateTime + '</td>');
        //team.append('<td><input type="button" value="修改" class="modify-btn" name="queryDisc-modify-btn"/></td>');
        $("#J_queryDisc").append(team);
    }
}

// 查询单个优惠信息
// function queryDiscId(){
//     for (var i = 0; i < data.length; i++) {
//         var team = $('<tr></tr>');
//         team.append('<td>' + data[i].discountInfNumber + '</td>');
//         team.append('<td>' + data[i].discountInfName + '</td>');
//         team.append('<td>' + data[i].discountAmount + '</td>');
//         team.append('<td>' + data[i].discountDescription + '</td>');
//         team.append('<td>' + data[i].founder + '</td>');
//         team.append('<td>' + data[i].founderTime + '</td>');
//         team.append('<td>' + data[i].updater + '</td>');
//         team.append('<td>' + data[i].updateTime + '</td>');
//         team.append('<td><input type="button" value="修改" class="modify-btn"/></td>');
//         $("#J_queryDiscId").append(team);
//     }
// }